package com.learn.xueer.ui.viewmodel

import androidx.lifecycle.MutableLiveData
import com.learn.xueer.app.network.apiService
import com.learn.xueer.data.model.bean.PkResultResponse
import me.hgj.jetpackmvvm.base.viewmodel.BaseViewModel
import me.hgj.jetpackmvvm.ext.request

class PkResultViewModel : BaseViewModel() {

    var pkResultData = MutableLiveData<PkResultResponse>()


    fun savePk(isWin: Boolean) {
        request({ apiService.savePk(if (isWin) 1 else 0) }, {}, {}, false)
    }
}